package com.learn.factory.method.weapon;

import com.learn.factory.method.Weapon;
import com.learn.factory.method.WeaponType;
import lombok.extern.slf4j.Slf4j;

/**
 * <p>项目名称: design-pattern </p>
 *
 * <p>文件名称: WuhanWeapon </p>
 *
 * implementor of Weapon
 */
@Slf4j
public class BeijingWeapon implements Weapon {

    private WeaponType weaponType;

    public BeijingWeapon(WeaponType weaponType) {
        log.info("开始生产{}", weaponType);
        this.weaponType = weaponType;
        log.info("生产完成{}", weaponType);
    }

    @Override
    public WeaponType getWeaponType() {
        return weaponType;
    }

    @Override
    public String toString() {
        return "WuhanWeapon{" +
                "weaponType=" + weaponType +
                '}';
    }
}
